﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="USProducts.ascx.cs" Inherits="USProducts" %>
<style type="text/css">
        html
        {
            background-color: Silver;
        }
        .tabs
        {
            position:inherit;
            top: 1px;
            right: 10px;
        }
        .tab
        {
            border: solid 1px black;
            background-color: #eeeeee;
            padding: 2px 10px;
        }
        .tabselected
        {
           
             background-color: Aqua;
            border-bottom: solid 1px while;
        }
    
         .hightlighrow
         {
             background-color:#87CEEB;
         }
          .iframe
        {
        overflow-x: hidden;
        overflow-y: scroll;
        }
       
    </style>
 <div style=" height:791px; width:768px">
 <div style="height:30px">
 </div>
 <div></div>
 <div style="font-family: Cambria; font-size: 36px; font-weight: bold; color: #000000;" >
       &nbsp;&nbsp; [<asp:Label ID="lbProduct" runat="server" Text="PRODUCT" Font-Bold="True" 
           Font-Names="Cambria" Font-Size="30px"></asp:Label>
       
       ]&nbsp;
       
     <asp:Button ID="btnProduct_type" Text="PRODUCT TYPE" runat="server" 
             Width="140px" onclick="btnProduct_type_Click" Font-Bold="True" 
           Font-Names="Cambria" Height="33px" Font-Size="16px"/>
           
           
   <asp:Button ID="btnProduct" Text="PRODUCT" runat="server" 
             Width="122px" onclick="btnProduct_Click" Font-Bold="True" 
           Font-Names="Cambria" Font-Size="16px" Height="33px"/>
    </div>
    <div style="height:20px">
 </div>
    <asp:MultiView ID="Multiview1" runat="server">
         
       <asp:View ID="Product_Type" runat="server">
       <div class="iframe" style=" height:645px; width:768px" align="center">
           &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
           
               <asp:GridView ID="GrvProduct_type" runat="server" AutoGenerateColumns="False" 
                   BackColor="White" BorderColor="#E7E7FF" BorderStyle="None" BorderWidth="1px" 
                   CellPadding="3" DataKeyNames="PROTYP_ID" GridLines="Horizontal" Height="640px" 
                   onrowediting="GrvProduct_type_RowEditing" 
                   onrowupdating="GrvProduct_type_RowUpdating" 
        
                   ShowFooter="True" Width="760px">
                   <RowStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" />
                   <Columns>
                       <asp:TemplateField HeaderStyle-Font-Size="17px" HeaderText="ProductType_ID" 
                           Visible="False">
                           <ItemTemplate>
                               <asp:Label ID="lbProtyp_ID" runat="server" Text='<%# Eval("PROTYP_ID") %>'></asp:Label>
                           </ItemTemplate>
                           <HeaderStyle Width="15%" />
                           <ItemStyle Font-Size="17px" />
                       </asp:TemplateField>
                       <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                           HeaderStyle-Height="30px" HeaderText="PRODUCT TYPE NAME">
                           <EditItemTemplate>
                               <asp:TextBox ID="txtProductType_Name" runat="server" Font-Size="17px" 
                                   Text='<%# Bind("PROTYP_NAME") %>' Width="100%"></asp:TextBox>
                           </EditItemTemplate>
                           <FooterTemplate>
                               <asp:TextBox ID="txtNewProductType_Name" runat="server" Font-Size="17px" 
                                   Width="100%"></asp:TextBox>
                           </FooterTemplate>
                           <ItemTemplate>
                               <asp:LinkButton ID="lbtProtyp_Name" runat="server" CausesValidation="False" 
                                   CommandName="Edit">
                               <asp:Label ID="lbProtyp_Name" runat="server" Text='<%# Bind("PROTYP_NAME") %>' 
                                   Width="100%"></asp:Label>
                               </asp:LinkButton>
                           </ItemTemplate>
                           <HeaderStyle Width="50%" />
                           <ItemStyle Font-Size="17px" HorizontalAlign="Left" />
                       </asp:TemplateField>
                       <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                           HeaderText="Edit" ItemStyle-HorizontalAlign="Center" ShowHeader="False" 
                           Visible="False">
                           <EditItemTemplate>
                               <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="True" 
                                   CommandName="Update" Text="Update"></asp:LinkButton>
                               <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" 
                                   CommandName="Cancel" Text="Cancel"></asp:LinkButton>
                           </EditItemTemplate>
                           <FooterTemplate>
                               <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" 
                                   CommandName="AddNewProduct" Text="Add"></asp:LinkButton>
                           </FooterTemplate>
                           <ItemTemplate>
                               <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" 
                                   CommandName="Edit" Text="Edit"></asp:LinkButton>
                           </ItemTemplate>
                           <HeaderStyle Width="20%" />
                           <ItemStyle Font-Size="17px" />
                       </asp:TemplateField>
                   </Columns>
                   <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" />
                   <PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" />
                   <SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" 
                       HorizontalAlign="Center" />
                   <HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#F7F7F7" 
                       Height="30px" />
                   <AlternatingRowStyle BackColor="#F7F7F7" />
               </asp:GridView>
             
             
           </div>
             <div style="height:10px">
             </div>
                    <div style="width:760px" >
                    <center>
                  <asp:Button ID="btnDeleteProTyp" runat="server" Text="DELETE" Width="80px" Height="30px" 
                  onclick="btnDeleteProTyp_Click" Font-Bold="True" Font-Size="16px" 
                  ForeColor="Black" Font-Names="Cambria" />
     <asp:Button ID="btnAdd_ProTyp" runat="server" Text="ADD" onclick="btnAdd_ProTyp_Click" 
                  Width="80px" Height="30px" Font-Bold="True" Font-Size="16px" 
                  ForeColor="Black" Font-Names="Cambria" />
       <asp:Button ID="btnEditProTyp" runat="server" Width="80px" Height="30px" Text="EDIT" 
                  Font-Bold="True" Font-Size="16px" ForeColor="Black" 
                  Font-Names="Cambria"  onclick="btnEditProTyp_Click" />
                  </center>
                   </div>
                    <div style="height:15px">
             </div >
             
           </asp:View>
           
          <asp:View ID="Product" runat="server" >
          <div class="iframe" style=" height:645px ; width:768px " align="center">
              <asp:GridView ID="GrvProduct" runat="server" AllowSorting="True" 
                  AutoGenerateColumns="False" BackColor="White" BorderColor="#E7E7FF" 
                  BorderStyle="None" BorderWidth="1px" CellPadding="3" DataKeyNames="PRO_ID" 
                  GridLines="Horizontal" Height="640px" 
                  OnRowCancelingEdit="GrvProduct_RowCancelingEdit" 
                  onrowdatabound="GrvProduct_RowDataBound1" OnRowEditing="GrvProduct_RowEditing" 
                  onrowupdating="GrvProduct_RowUpdating" ShowFooter="True" Width="760px">
                  <RowStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" />
                  <Columns>
                      <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                          HeaderText="TYPE NAME">
                          <EditItemTemplate>
                              <asp:DropDownList ID="cmbProductType_ID" runat="server" 
                                  DataTextField="PROTYP_NAME" DataValueField="PROTYP_ID" Font-Size="17px" 
                                  Width="100%">
                              </asp:DropDownList>
                          </EditItemTemplate>
                          <ItemTemplate>
                              <asp:LinkButton ID="lbtPROTYPE_ID" runat="server" CausesValidation="False" 
                                  CommandName="Edit">
                              <asp:Label ID="lbPROTYP_ID" runat="server" Text='<%# Eval("PROTYP_NAME") %>'></asp:Label>
                              </asp:LinkButton>
                          </ItemTemplate>
                          <FooterTemplate>
                              <asp:DropDownList ID="cmbNewProductType_ID" runat="server" 
                                  DataTextField="PROTYP_NAME" DataValueField="PROTYP_ID" Font-Size="17px" 
                                  Width="100%">
                              </asp:DropDownList>
                          </FooterTemplate>
                          <HeaderStyle Width="20%" />
                          <ItemStyle Font-Size="17px" />
                      </asp:TemplateField>
                      <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                          HeaderText="NAME">
                          <EditItemTemplate>
                              <asp:TextBox ID="txtProduct_Name" runat="server" Font-Size="17px" 
                                  Text='<%# Bind("PRO_NAME") %>' Width="100%"></asp:TextBox>
                          </EditItemTemplate>
                          <FooterTemplate>
                              <asp:TextBox ID="txtNewProduct_Name" runat="server" Font-Size="17px" 
                                  Width="100%"></asp:TextBox>
                          </FooterTemplate>
                          <ItemTemplate>
                              <asp:LinkButton ID="lbtPRO_NAME" runat="server" CausesValidation="False" 
                                  CommandName="Edit">
                              <asp:Label ID="lbPRO_NAME" runat="server" Text='<%# Bind("PRO_NAME") %>'></asp:Label>
                              </asp:LinkButton>
                          </ItemTemplate>
                          <HeaderStyle Width="20%" />
                          <ItemStyle Font-Size="17px" />
                      </asp:TemplateField>
                      <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                          HeaderText="DESCRIPTION">
                          <EditItemTemplate>
                              <asp:TextBox ID="txtProduct_Des" runat="server" Font-Size="17px" 
                                  Text='<%# Bind("PRO_DESCRIPTION") %>' Width="100%"></asp:TextBox>
                          </EditItemTemplate>
                          <FooterTemplate>
                              <asp:TextBox ID="txtNewProduct_Des" runat="server" Font-Size="17px" 
                                  Width="100%"></asp:TextBox>
                          </FooterTemplate>
                          <ItemTemplate>
                              <asp:LinkButton ID="lbtPRO_DESCRIPTION" runat="server" CausesValidation="False" 
                                  CommandName="Edit">
                              <asp:Label ID="lbPRO_DESCRIPTION" runat="server" 
                                  Text='<%# Bind("PRO_DESCRIPTION") %>' Width="100%"></asp:Label>
                              </asp:LinkButton>
                          </ItemTemplate>
                          <HeaderStyle Width="35%" />
                          <ItemStyle Font-Size="17px" />
                      </asp:TemplateField>
                      <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                          HeaderText="PRICE">
                          <EditItemTemplate>
                              <asp:TextBox ID="txtProduct_Price" runat="server" Font-Size="17px" 
                                  Text='<%# Bind("PRO_PRICE") %>' Width="100%"></asp:TextBox>
                          </EditItemTemplate>
                          <FooterTemplate>
                              <asp:TextBox ID="txtNewProduct_Price" runat="server" Font-Size="17px" 
                                  Width="100%"></asp:TextBox>
                          </FooterTemplate>
                          <ItemTemplate>
                              <asp:LinkButton ID="lbtPRO_Price" runat="server" CausesValidation="False" 
                                  CommandName="Edit">
                              <asp:Label ID="lbPRO_PRICE" runat="server" Text='<%# Bind("Prices") %>' 
                                  Width="100%"></asp:Label>
                              </asp:LinkButton>
                          </ItemTemplate>
                          <HeaderStyle Width="10%" />
                          <ItemStyle Font-Size="17px" />
                      </asp:TemplateField>
                      <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                          HeaderText="QTY">
                          <EditItemTemplate>
                              <asp:TextBox ID="txtProduct_Quantity" runat="server" Font-Size="17px" 
                                  Text='<%# Bind("PRO_QUANTITY") %>' Width="100%"></asp:TextBox>
                          </EditItemTemplate>
                          <FooterTemplate>
                              <asp:TextBox ID="txtNewProduct_Quantity" runat="server" Font-Size="17px" 
                                  Width="100%"></asp:TextBox>
                          </FooterTemplate>
                          <ItemTemplate>
                              <asp:LinkButton ID="lbtPRO_QTY" runat="server" CausesValidation="False" 
                                  CommandName="Edit">
                              <asp:Label ID="lbPRO_QUANTITY" runat="server" 
                                  Text='<%# Bind("PRO_QUANTITY") %>'></asp:Label>
                              </asp:LinkButton>
                          </ItemTemplate>
                          <HeaderStyle Width="10%" />
                          <ItemStyle Font-Size="17px" />
                      </asp:TemplateField>
                      <asp:TemplateField HeaderStyle-BackColor="#FF9933" HeaderStyle-Font-Size="17px" 
                          HeaderText="Edit" ItemStyle-HorizontalAlign="Center" ItemStyle-Width="70px" 
                          ShowHeader="False" Visible="False">
                          <EditItemTemplate>
                              <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="True" 
                                  CommandName="Update" Text="Update"></asp:LinkButton>
                              <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" 
                                  CommandName="Cancel" Text="Cancel"></asp:LinkButton>
                          </EditItemTemplate>
                          <FooterTemplate>
                              <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" 
                                  CommandName="AddNewProduct" Text=" Add "></asp:LinkButton>
                          </FooterTemplate>
                          <ItemTemplate>
                              <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" 
                                  CommandName="Edit" Text="Edit"></asp:LinkButton>
                          </ItemTemplate>
                          <HeaderStyle Width="20%" />
                          <ItemStyle />
                      </asp:TemplateField>
                  </Columns>
                  <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" />
                  <PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" />
                  <SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" />
                  <HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#F7F7F7" 
                      Height="30px" />
                  <AlternatingRowStyle BackColor="#F7F7F7" />
              </asp:GridView>
              
             </div>
             <div style="height:10px">
             </div >
                   <div style="width:768px"  ><center>
    <asp:Button ID="btnDeletePro" runat="server" Text="DELETE" Width="80px" Height="30px"  
                  onclick="btnDeletePro_Click1" Font-Bold="True" Font-Size="16px" 
                  ForeColor="Black" Font-Names="Cambria" />
     <asp:Button ID="btnAdd_Pro" runat="server" Text="ADD" onclick="btnAdd_Pro_Click" 
                  Width="80px" Height="30px" Font-Bold="True" Font-Size="16px" 
                  ForeColor="Black" Font-Names="Cambria" />
       <asp:Button ID="btnEditPro" runat="server" Width="80px" Height="30px"  Text="EDIT" 
                  Font-Bold="True" Font-Size="16px" ForeColor="Black" 
                  Font-Names="Cambria"   /> </center>    
               </div> 
      <div style="height:15px">
             </div >
   
   </asp:View>
   
    </asp:MultiView>
    
    
    </div>
